package com.casic.ops.consts.user;


import com.casic.ops.entity.dto.UserDTO;


/**
 * @ClassName ops-platform
 * @Description 用户信息
 * @Author mianbin
 * @Date 2022/5/31 10:59
 * @Version 1.0
 **/
public class UserHolder {

    private static final ThreadLocal<UserDTO> LOCAL = new ThreadLocal<>();

    public static UserDTO get() {
        return LOCAL.get();
    }

    public static void set(UserDTO user) {
        LOCAL.set(user);
    }

    public static void remove() {
        LOCAL.remove();
    }

}
